   /* SHOW PURCHASE RECEIVERS INVOICED BY THIS VOUCHER */
DEFINE VARIABLE pur_amt LIKE vph_curr_amt.
DEFINE VARIABLE inv_amt LIKE vph_curr_amt.
/*
   for each vph_hist NO-LOCK USE-INDEX vph_ref,    /*where vph_ref = ap_ref*/
          each pvo_mstr no-lock where
               pvo_lc_charge   = "" and
               /*pvo_internal_ref_type = {&TYPE_POReceiver} and*/
               pvo_id = vph_pvo_id
            with frame a width 150:

         find prh_hist where prh_receiver = pvo_internal_ref
            and prh_line = pvo_line no-lock no-error.     */

   for each prh_hist NO-LOCK,    
       EACH pvo_mstr NO-LOCK WHERE prh_receiver = pvo_internal_ref AND prh_line = pvo_line AND pvo_internal_ref_type = "07",
       EACH vph_hist NO-LOCK WHERE vph_pvo_id = pvo_id WITH FRAME a WIDTH 150.

            display space(4)
               prh_receiver
               prh_line
               prh_nbr
               prh_part
               prh_um
               prh_type
               prh_rcvd
               vph_inv_qty
               prh_curr
               prh_curr_amt
               vph_curr_amt
               vph_adj_amt.                                  /*vo_curr*/

   
   end. /*if show purchase receipts*/
